import type {ComfyUIProperties} from "~/utils/comfyuiApi";

type PropertyKey = keyof ComfyUIProperties

export const NodeToParam=[
    {
        param: 'seed' as PropertyKey,
        title: '随机种子',
        node: [
            {
                nodeClass: 'KSampler',
                paramKey: 'seed',
            },
            {
                nodeClass: 'KSampler (Efficient)',
                paramKey: 'seed',
            },
            {
                nodeClass: 'KSamplerAdvanced',
                paramKey: 'noise_seed',
            },
        ],
    },
    {
        param: 'ckpt_name' as PropertyKey,
        title: '大模型',
        node: [
            {
                nodeClass: 'CheckpointLoaderSimple',
                paramKey: 'ckpt_name',
            },
            {
                nodeClass: 'Efficient Loader',
                paramKey: 'ckpt_name',
            }
        ],
    },
    {
        param: 'width' as PropertyKey,
        title: '宽度',
        node: [
            {
                nodeClass: 'EmptyLatentImage',
                paramKey: 'width',
            },
            {
                nodeClass: 'Efficient Loader',
                paramKey: 'empty_latent_width',
            },
            {
                nodeClass: 'EmptySD3LatentImage',
                paramKey: 'width',
            }
        ],
    },
    {
        param: 'height' as PropertyKey,
        title: '高度',
        node: [
            {
                nodeClass: 'EmptyLatentImage',
                paramKey: 'height',
            },
            {
                nodeClass: 'Efficient Loader',
                paramKey: 'empty_latent_height',
            },
            {
                nodeClass: 'EmptySD3LatentImage',
                paramKey: 'height',
            }
        ],
    },
    {
        param: 'positive' as PropertyKey,
        title: '正向提示词',
        node: [
            {
                nodeClass: 'ZFTextTranslation',
                paramKey: 'text',
            }
        ],
    },
    {
        param: 'negative' as PropertyKey,
        title: '反向提示词',
        node: [
            {
                nodeClass: 'ZFTextTranslation',
                paramKey: 'text',
            }
        ],
    }
]